package com.golxen.framework.module;

import com.golxen.framework.user.player.GamePlayer;

public abstract class AbstractModule {

	protected GamePlayer player;
	protected Object saveLockObj = new Object();

	public AbstractModule(GamePlayer player) {
		this.player = player;
	}

	public abstract boolean loadDB();

	public abstract boolean afterLoadDB();

	public abstract boolean saveDB();

	public void resetDay() {

	}

	public void afterLogin() {

	}

	public void update() {

	}


	public Class<?> getModuleType() {
		return this.getClass();
	}

	public void loginSendMsg() {

	}

	public Object getSaveLockObj() {
		return saveLockObj;
	}

	public long getUserId() {
		return player.getUserId();
	}
}
